﻿@model LoggedOutViewModel
@{
    ViewData["Title"] = "登出界面";
}

<div class="page-header logged-out">
    <h1>
        Logout
        <small>You are now logged out</small>
    </h1>

    @if (Model.PostLogoutRedirectUri != null)
    {
        <div>
            Click <a class="PostLogoutRedirectUri" href="@Model.PostLogoutRedirectUri">here</a> to return to the
            <span>@Model.ClientName</span> application.
        </div>
    }

    @if (Model.SignOutIframeUrl != null)
    {
        <iframe width="0" height="0" class="signout" src="@Model.SignOutIframeUrl"></iframe>
    }
</div>

@section scripts {
    @if (Model.AutomaticRedirectAfterSignOut)
    {
        <script type="application/json">
            window.addEventListener("load", function () {
            var a = document.querySelector("a.PostLogoutRedirectUri");
            if (a) {
            window.location = a.href;
            }
            });
        </script>
    }
}


